{include file="inc/header.html"} 
<style>
	.f_yj{ behavior:url(iecss3.htc); }
</style>
<script type="text/javascript" src="{$TMPL}/js/jscharts_cr.js"></script>
<?php
$this->_var['indexcss'][] = $this->_var['TMPL_REAL']."/css/index.css";
?>
<link rel="stylesheet" type="text/css" href="{function name="parse_css" v="$indexcss"}" />
<div class="blank"></div>
<div class="feature">
	<a class="fea1">
		<i></i>
		<h3>多重保证</h3>
		<span>1000万本息保障机构全额担保</span>
	</a>
	<a class="fea2">
		<i></i>
		<h3>低门槛高收益</h3>
		<span>百元起投14-18%年化收益率</span>
	</a>
	<a class="fea3">
		<i></i>
		<h3>灵活的投资赎回</h3>
		<span>债权转让功能方便灵活回收资金</span>
	</a>
	<a class="fea4">
		<i></i>
		<h3>随时随地理财</h3>
		<span>下载手机客户端，随时随地轻松理财</span>
	</a>
</div>

<div class="clearfix">
    <div class="index_left">
    <div class="list_title clearfix">
        <div class="list_tt list1 cur">投资列表</div>
        <div class="list_tt list2">债权转让</div>
    </div>
    <div class="panes">
    <div class="i_deal_list">
    	{foreach from=$deal_list item="deal" key=key name="deal"}
        <ul class="clearfix">
            <li class="i_deal_list_left"><img src="{$deal.icon}" width="80" height="80"/></li>
            <li class="i_deal_list_title">
            	<div class="idl_title"><a href="{$deal.url}" target="_blank" title="{$deal.name}">{$deal.sub_name}</a></div>
                <div>年化收益：{$deal.rate} %</div>
                <div>信用等级：<img src="{$TMPL}/images/{$deal.user.point_level}.png" align="absmiddle" title="{$deal.user.point_level}" alt="{$deal.user.point_level}" height="40" /></div>
            </li>
            <li class="i_deal_list_mid">
                <div>
                	<div class=" mitem">
                    	<div>
                            <img src="{$deal.cate_info.icon}"  height="25" class="ico" title="{$deal.cate_info.name}" />
                            {if $deal.user_bid_rebate > 0}
                            <span class="reward"><label>奖</label> {$deal.user_bid_rebate}%</span>
                            {/if}
                            
                        </div>
                        <div>借款金额：<span class="m_money">¥{$deal.borrow_amount}</span></div>
                        <div>还款方式：<span class="gray">{if $deal.loantype==0}等额本息{elseif $deal.loantype==1}付息还本{elseif $deal.loantype==2}到期还本息{/if}</span></div>
                    </div>
                    <div class=" mitem">
                    	<div>发布时间：{$deal.publish_time_format}</div>
                        <div>借款期限	：{$deal.repay_time}{if $deal.repay_time_type eq 0}天{else}个月{/if}</div>
                        <div>剩余时间：<span class="gray">{$deal.remain_time_format}</span></div>
                    </div>
                </div>
            </li>
            <li class="i_deal_list_right">
            	<div class="idlr_remain">剩余金额：<span class="m_money">{if $deal.uloadtype eq 0}{$deal.need_money}{else}{$deal.need_portion}{/if}</span><span class="idlr_sm"> 已投<span class="m_money">{$deal.buy_count}</span>笔</span></div>
                <div class="idlr_bar">
                    <div class="blueProgressBar progressBar f_l">
                        <div class="p">
                        {if  $deal.deal_status eq 5}
                            <div class="c" style="width: 100%;background:url('{$TMPL}/images/progressBarBg.png') repeat-x"></div>
                        {elseif $deal.deal_status eq 4}
                            <div class="c" style="width: {function name='round' val=$deal.repay_progress_point f=3}%;background:url('{$TMPL}/images/progressBarBg.png') repeat-x"></div>
                        {else}
                            <div class="c" style="width: {function name='round' val=$deal.progress_point f=3}%;background:url('{$TMPL}/images/progressBarBg.png') repeat-x"></div>
                        {/if}
                        </div>
                    </div>
                    <div class="m_rate f_l">
                    	{if  $deal.deal_status eq 5}
                            100%
                        {elseif $deal.deal_status eq 4}
                            {function name='round' v='$deal.repay_progress_point' f=0}%
                        {else}
                            {function name="round" v=$deal.progress_point f=0}%
                        {/if}
                    </div>
                </div>
                <div class="clear">
                	<a href="{$deal.url}" target="_blank">
                        {if $deal.is_delete eq 2}
                            <span class="f_white">待发布</span>
                        {elseif $deal.is_wait eq 1}
                            <span class="f_white">未开始</span>
                        {elseif $deal.deal_status eq 5}
                            <span class="f_white f_green">还款完毕</span>
                        {elseif $deal.deal_status eq 4}
                            <span class="f_white f_green">还款中</span>
                        {elseif $deal.deal_status eq 0}
                            <span class="f_white">等待材料</span>
                        {elseif $deal.deal_status eq 1 && $deal.remain_time gt 0}
                            <span class="f_white">立即投资</span>
                        {elseif $deal.deal_status eq 2}
                            <span class="f_white f_orange">满标</span>
                        {elseif $deal.deal_status eq 3 || $deal.remain_time lte 0}
                            <span class="f_white f_gray">流标</span>
                        {/if}
                    </a>
                </div>
            </li>
        </ul>
       {/foreach}
       <a href="{url x="index" r="deals"}" title="{$LANG.MORE}" class="more">查看更多借款列表</a>
    </div>
    <div class="i_deal_list clearfix" style="display:none;">
        <table width="100%" border="0" cellspacing="0" cellpadding="0" style="font-size:12px;">
            <tr  border="0" style="background-color:#00bef0; color:#fff; height:34px;">
                <th>标题</th>
                <th style="width:15%">   转让人  / 承接人</th>
                <th style="width:15%">本/息/转让金</th>
                <th style="width:10%">利率</th>
                <th style="width:10%">待还/总期数</th>
                <th style="width:10%">信用等级</th>
                <th style="width:20%">剩余时间</th>
            </tr>
            {foreach from=$transfer_list item="transfer" key=key name="transfer"}
            <tr class="item {if $key mod 2 eq 1}item_1{/if} tc">
                <td style="text-align:left">
                    &nbsp;&nbsp;<img src="{$transfer.cate_info.icon}" height="25" class="ico" title="{$deal.cate_info.name}" /> 
                    <a href="{$transfer.url}" target="_blank">
                       {$transfer.name}
                    </a>
                </td>
                <td>
                    <div><a href="{$transfer.user.url}" target="_blank">{$transfer.user.user_name}</a></div>
                    {if $transfer.tuser}
                      <div><a href="{$transfer.tuser.url}" target="_blank">{$transfer.tuser.user_name}</a></div>
                    {/if }
                </td>
                <td>
                    <div>{$transfer.left_benjin_format}</div>
                    <div>{$transfer.left_lixi_format}</div>
                    <div>
                        {function name="format_price" v="$transfer.transfer_amount"}
                    </div>
                </td>    
                <td>
                    <div>
                        {function name="number_format" v="$transfer.rate" f="2"}%
                    </div>
                      
                </td>
                <td>
                    <span class="f_red">{$transfer.how_much_month}/{$transfer.repay_time}</span>
                </td>
                <td>
                    <a href="{$transfer.duser.url}" target="_blank"><img src="{$TMPL}/images/{$transfer.duser.point_level}.png" width="40" align="absmiddle" alt="{$transfer.duser.point_level}" title="{$transfer.duser.point_level}"></a>
                </td>
                <td>
                    {if $transfer.t_user_id gt 0}
                        已转让
                    {else}
                        {if $transfer.status eq 0}
                            已撤销
                        {else}
                        {$transfer.remain_time_format}
                        {if $transfer.remain_time lt 0}
                            逾期还款
                        {/if}
                        {/if}
                    {/if}
                </td>
            </tr>
            {/foreach}
        </table>
        <a href="{url x="index" r="transfer"}" title="{$LANG.MORE}" class="more">查看更多债权列表</a>
    </div>
    </div>
    </div>
    <div class="blank20"></div>
    <div id="loadtop" class="index_fr index_lc r-block mr40 f_l">
    <div class="relative clearfix">
        <div class="nav_title">理财风云榜</div>
        <div id="rightTitls">
            <ul>
                <li class="current"><a rel="1">月</a></li>
                <li><a rel="2">周</a></li>
                
                <li><a rel="3">天</a></li>
            </ul>
        </div>
    </div>
    
    <div id="J_conbox" >
        <ul class="clearfix" rel="1">
        	<li class="clearfix pl10 pt10 pb5">
                <span class="nums tc">排名</span>
                <span class="uname">用户名</span>
                <span class="money">投资金额</span>
            </li>
            {foreach from="$month_load_top_list" item="load" name="loads"}
            <li class="clearfix pl10 {if $smarty.foreach.loads.iteration < 4}libg{/if}">
                <span class="nums tc">{$smarty.foreach.loads.iteration}</span>
                <span class="uname">{function name="utf_substr" v="$load.user_name"}</span>
                <span class="money">{function name="format_price" v=$load.total_money f=2}</span>
            </li>
            {/foreach}
        </ul>
        <ul class="clearfix hide" rel="2">
        	<li class="clearfix pl10 pt10 pb5">
                <span class="nums tc">排名</span>
                <span class="uname">用户名</span>
                <span class="money">投资金额</span>
            </li>
            {foreach from="$week_load_top_list" item="load" name="loads"}
            <li class="clearfix pl10 {if $smarty.foreach.loads.iteration < 4}libg{/if}">
                <span class="nums tc">{$smarty.foreach.loads.iteration}</span>
                <span class="uname">{function name="utf_substr" v="$load.user_name"}</span>
                <span class="money">{function name="format_price" v=$load.total_money f=2}</span>
            </li>
            {/foreach}
        </ul>
        <ul class="clearfix hide" rel="3">
        	<li class="clearfix pl10 pt10 pb5">
                <span class="nums tc">排名</span>
                <span class="uname">用户名</span>
                <span class="money">投资金额</span>
            </li>
            {foreach from="$day_load_top_list" item="load" name="loads"}
            <li class="clearfix pl10 {if $smarty.foreach.loads.iteration < 4}libg{/if}">
                <span class="nums tc">{$smarty.foreach.loads.iteration}</span>
                <span class="uname">{function name="utf_substr" v="$load.user_name"}</span>
                <span class="money">{function name="format_price" v=$load.total_money f=2}</span>
            </li>
            {/foreach}
        </ul>
    </div>
    </div>
    <script type="text/javascript">
    jQuery(function(){
        $("#loadtop #rightTitls a").click(function(){
            $("#loadtop #rightTitls a").parent().removeClass("current");
            $(this).parent().addClass("current");
            var rel=$(this).attr("rel");
            $("#loadtop #J_conbox ul").addClass("hide");
            $("#loadtop #J_conbox ul[rel='"+rel+"']").removeClass("hide");
        });
    });
    </script>
    
    <div class="index_fr index_notice r-block f_l">
    <div class="relative clearfix">
        <div class="nav_title">网站公告</div>
        <div class="notice_more">
            <div>
                <span style="font-weight: normal;">
                    <a href="{url x="index" r="notice#list_notice"}"> 更多 >></a>
                </span>
            </div>
        </div>
    </div>
    <div class="notice-list clearfix">
        <ul>
            {foreach from=$notice_list item="notice"}
            <li>
                <span class="n_title">
                <a href="{$notice.url}" title="{$notice.title}" target="_blank">{function name="msubstr" v=$notice.title s=0 e=18}</a>
                </span>
                <span class="n_date">{function name="to_date" v="$notice.update_time" f="Y-m-d"}</span>
            </li>
            {/foreach}
        </ul>
    </div>
    </div>
    
    <div class="index_fr r-block f_r relative">
    <img src="{$TMPL}/images/dosomthing.jpg" />
    <a class="borrow_out ps" href="{url x="index" r="deals"}" target="_blank">我要借出</a>
    <a class="borrow_in ps" href="{url x="index" r="borrow"}" target="_blank">我要借款</a>
    </div>
</div>

{if $f_link_data}
<div class="blank20"></div>
<div class="flink">
{foreach from=$f_link_data item=link_group}			
    <div class="nav_title">{$link_group.name}</div>
    {foreach from=$link_group.links item=link}
        <a href="http://{$link.url}" target="_blank" title="{if $link.description}{$link.description}{else}{$link.name}{/if}">{if $link.img neq ''}<img src='{$link.img}' alt="{if $link.description}{$link.description}{else}{$link.name}{/if}" />{else}{$link.name}{/if}</a>
    {/foreach}
{/foreach}
</div>	
{/if}

{include file="inc/footer.html"}
<script type="text/javascript">
$(function(){	
	$("#case").find("li:odd").css("backgroundColor","#f9f9f9");

   	var $div_li = $(".list_title .list_tt");
   	$div_li.click(function(){
          $(this).addClass("cur").siblings().removeClass("cur");
          var div_index = $div_li.index(this);
          $(".panes").find(".i_deal_list").eq(div_index).show().siblings().hide();
   	});   	
})
</script>